package com.tuo51.evaluate.domain.childrens;

import lombok.Data;
import lombok.NoArgsConstructor;

import javax.persistence.*;
import java.util.Date;

/**
 * *******************************
 * Created by Ron.
 * form com.tuo51
 * on 2017/7/13
 * *******************************
 */
@Entity
@Data
@Table(name = "rel_staff_children", uniqueConstraints = {
        @UniqueConstraint(columnNames = {
                "staffId", "defaultChildrenId"
        })
})
@NoArgsConstructor
public class RelStaffChildren  {

    @Column(columnDefinition = " datetime DEFAULT NOW() COMMENT '创建时间' ")
    private Date created = new Date();

    @Column(columnDefinition = " varchar(32)  COMMENT '宝宝id'")
    private String defaultChildrenId;

    @Id
    @Column(columnDefinition = " varchar(32)  COMMENT '机构id'")  //默认的
    private String staffId;

}
